<template>
    <div>
        <p @click="count1++">我是子组件--{{ count1 }}--{{ username }}</p>
        <ul>
            <li v-for="item in shoplistArr" :key="item.id">{{ item.proname }}--{{ item.price }}</li>
        </ul>
    </div>
</template>

<script>
export default {
    data() {
        return {
            msg: '123'
        }
    },
    props: [
        'count1',
        'username',
        'shoplistArr',
        "addcount"
    ], //接收的属性名
    mounted() {
        console.log('this-son', this);
        // console.log(this.count1);
        // this.count1++
    },
    methods: {
        addcount1() {
            this.count1++
        }
    }
}
</script>
<style scoped></style>